<template>
  <el-config-provider :locale="zhLocale">
    <router-view />
  </el-config-provider>
</template>

<script lang="ts">
  import { defineComponent, ref } from 'vue'
  import { ElConfigProvider } from 'element-plus'
  import zhCn from 'element-plus/lib/locale/lang/zh-cn'
  export default defineComponent({
    name: 'App',
    components: {
      [ElConfigProvider.name]: ElConfigProvider //添加组件
    },
    setup() {
      let zhLocale = ref(zhCn)
      return {
        zhLocale
      }
    }
  })
</script>

<style></style>
